acceleratorText
Type
property
Summary
Specifies the shortcut hint that appears at the right edge of a button.
Syntax
set the accel[erator]Text of <button> to <string>
Description
Use the acceleratorText property to provide the user with an onscreen hint about the shortcut key combination specified by the button's acceleratorKey property.
The acceleratorText string appears at the right edge of the button, inside the button's rightMargin. LiveCode does not automatically make room for the acceleratorText string, so you might need to enlarge the button to prevent its label from overlapping the acceleratorText string.
If the button's textAlign property is set to "right", the button's label overlaps the acceleratorText string, so you shouldn't set a button's acceleratorText if it has a right-aligned label.
Usually, the string should be the character in acceleratorKey, but you might want to include additional characters to hint at the modifier key needed.
Nothing happens when the user presses the key specified by the acceleratorText property unless the acceleratorKey and acceleratorModifiers are set. The acceleratorText property creates a visual hint, but does not create the actual shortcut key combination.
Examples
set the acceleratorText of button 3 to "A"
set the accelText of button "Go" to field "Shortcut Key"
set the accelText of button 9 to "option-D"
set the accelText of the mouseControl to empty -- remove acceleratorText
Related
object: button
property: acceleratorModifiers, label, textAlign, acceleratorKey, rightMargin, mnemonic
glossary: property, key combination, modifier key
keyword: character, characters, button, string
Compatibility and Support
Introduced
LiveCode 1.0
OS
mac
windows
linux
Platforms
desktop